package com.zhuangjie.coupon.enums;

import com.zhuangjie.mvc.validator.annotate.enum_valid.VerifiableEnum;

/**
 * 优惠卷获取方式
 */
public enum CouponAcquisitionMethodType implements VerifiableEnum {
    EXCHANGE_CODE((byte) -1, "兑换码"),
    STORE_DISPLAY_MANUAL_RECEIPT((byte) 1, "店铺公开展示-手动领取"),
    NON_PUBLIC_GROUP_MANUAL_RECEIPT((byte) 2, "非公开群内手动领取");

    private final byte code;
    private final String name;

    CouponAcquisitionMethodType(byte code, String name) {
        this.code = code;
        this.name = name;
    }

    public byte getCode() {
        return code;
    }

    public String getName() {
        return name;
    }

    @Override
    public byte getValue() {
        return getCode();
    }
}